2 ==============================================================================
4 This file is part of the JUCE library - "Jules' Utility Class Extensions"
5 Copyright 2004-11 by Raw Material Software Ltd.
7 ------------------------------------------------------------------------------
9 JUCE can be redistributed and/or modified under the terms of the GNU General
10 Public License (Version 2), as published by the Free Software Foundation.
11 A copy of the license is included in the JUCE distribution, or can be found
12 online at www.gnu.org/licenses.
14 JUCE is distributed in the hope that it will be useful, but WITHOUT ANY
15 WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
16 A PARTICULAR PURPOSE. See the GNU General Public License for more details.
18 ------------------------------------------------------------------------------
20 To release a closed-source product which uses JUCE, commercial licenses are
21 available: visit www.rawmaterialsoftware.com/juce for more information.
23 ==============================================================================
26 #ifndef __JUCER_FONTPROPERTYCOMPONENT_JUCEHEADER__
27 #define __JUCER_FONTPROPERTYCOMPONENT_JUCEHEADER__
30 //==============================================================================
33 class FontPropertyComponent
: public ChoicePropertyComponent
36 FontPropertyComponent (const String
& name
);
37 ~FontPropertyComponent();
39 //==============================================================================
40 static const String defaultFont
;
41 static const String defaultSans
;
42 static const String defaultSerif
;
43 static const String defaultMono
;
45 static void preloadAllFonts();
47 virtual void setTypefaceName (const String
& newFontName
) = 0;
48 virtual const String
getTypefaceName() const = 0;
50 static const Font
applyNameToFont (const String
& typefaceName
, const Font
& font
);
51 static const String
getTypefaceNameCode (const String
& typefaceName
);
52 static const String
getFontStyleCode (const Font
& font
);
54 static const String
getCompleteFontCode (const Font
& font
, const String
& typefaceName
);
56 //==============================================================================
57 void setIndex (int newIndex
);
64 #endif // __JUCER_FONTPROPERTYCOMPONENT_JUCEHEADER__